import qs from 'qs'
import {
    request
} from './request.js'

//获取团购列表
export function getGroupBuyList(orderObj) {
    return request({
        url: 'group/listGroup',
        method: 'post',
        data: qs.stringify(orderObj)
    })
}

//获取商品列表
export function getProductList(orderObj) {
    return request({
        url: 'product/listShopProduct',
        method: 'post',
        data: qs.stringify(orderObj)
    })
}

//获取规格列表
export function getforlist(orderObj) {
    return request({
        url: 'product/listProductFormat',
        method: 'post',
        data: qs.stringify(orderObj)
    })
}


//新增团购
export function addGroupBuy(orderObj) {
    return request({
        url: 'group/addGroup',
        method: 'post',
        data: qs.stringify(orderObj),
    })
}

//获取已上线团购商品
export function getProductGroup(orderObj) {
    return request({
        url: 'product/getProductGroup',
        method: 'post',
        data: qs.stringify(orderObj),
    })
}